package com.ilibrary.web.action;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.HttpSession;

import net.sf.json.JSONObject;

import com.ilibrary.base.MyAjaxAction;
import com.ilibrary.constants.MyConstants;
import com.ilibrary.web.vo.AdminVO;

public class AjaxQuerySessionAdminAction extends MyAjaxAction {

	@Override
	protected JSONObject doExecute(HttpServletRequest request, HttpServletResponse response, HttpSession session) throws Exception {
		JSONObject jo = new JSONObject();
		AdminVO adminVO = (AdminVO) session.getAttribute(MyConstants.ILIBRARY_LOGIN_ADMIN);
		
		jo.put("adminId", adminVO.getAdminId());
		jo.put("adminName", adminVO.getAdminName());
		return jo;
	}

}
